home *** CD-ROM | disk | FTP | other *** search
/ Aminet 43 / Aminet 43 (2001)(GTI - Schatztruhe)[!][Jun 2001].iso / Aminet / mus / misc / NallePUH.readme < prev    next >
Text File  |  2001-05-03  |  4KB  |  117 lines

  1. Short:    Redirects any (hw-banging) sound program to AHI
  2. Author:   Martin Blom <martin@blom.org>
  3. Uploader: Martin Blom <martin@blom.org>
  4. Version:  0.2
  5. Type:     mus/misc
  6. Requires: An MMU, 68020+, AHI v4, OS 3.5 for GUI mode
  7.  
  8. Q: What is "Nalle Puh"?
  9. A: It's the Swedish name for Winnie the Pooh.
  10.  
  11. Q: Really?
  12. A: Yup.
  13.  
  14. Q: But... Ehm. What does this program, "Nalle PUH", do?
  15. A: It's a hack that intercepts some custom chip register accesses and
  16.    turns them into AHI function calls.
  17.  
  18. Q: How?
  19. A: By using the MMU to mark the page at $dff000 as invalid.
  20.  
  21. Q: Invalid? Doesn't that mean you will get an exception each time the OS
  22.    or an application touches the registers?
  23. A: Exactly.
  24.  
  25. Q: Isn't that kind of... slow?
  26. A: You bet.
  27.  
  28. Q: How slow?
  29. A: Unbearable.
  30.  
  31. Q: So the program is useless, then?
  32. A: Not quite. It can be instructed to patch the OS and all applications that
  33.    read or write to the custom chip registers, so that next time the 
  34.    instruction is executed, no exception will be generated.
  35.  
  36. Q: How?
  37. A: A new chip register area is created at $80dff000.  For the kickstart ROM,
  38.    all modules except audio.device will be patched to access this address
  39.    instead of $dff000. For applications, I simply guess when it's ok to
  40.    patch the instructions.
  41.  
  42. Q: Is that fool-proof?
  43. A: Of course not. It's a hack. A proof of concept. Nothing more.
  44.  
  45. Q: Alright then. So what programs can be redirected?
  46. A: I've tried the following programs, and they seem to work:
  47.  
  48.    * audio.device
  49.    * Digibooster 1.7
  50.    * Musicline Editor 1.5
  51.    * Octamed Soundstudio 1.03c
  52.    * Protracker (version 2.3 and 4.0)
  53.    * Sid4Amiga
  54.    * THX Sound System 2.3d.
  55.  
  56.    I've also tried the following, and they don't:
  57.    
  58.    * Delitracker 2.32
  59.    * Newtracker
  60.    * PlaySID
  61.  
  62.    (Note that Protracker disables multitasking and cannot be used with AHI
  63.    drivers that are not interrupt based.)
  64.  
  65. Q: Will you extend Nalle PUH so the all of those program work?
  66. A: Unlikely.
  67.  
  68. Q: Pretty, pretty please!
  69. A: No. The source code is available. Why don't you give it a shot yourself?
  70.  
  71. Q: Because <insert lame excuse here>.
  72. A: Too bad.
  73.  
  74. Q: Suppose I do fix the program, is there anything else I should do?
  75. A: You could certanly improve the instruction patching method. And it could
  76.    also be wise to set up a cachable Chip-RAM mirror so AHI won't have to
  77.    mix the samples from a non-cachable memory area. 
  78.  
  79. Q: Hey! I found a memory leak: You don't close mmu.library! And you don't
  80.    clean up the MMU tables fully either.
  81. A: I know.  The custom chip register mirror must stay if applications were
  82.    patched. mmu.library must not be flushed from memory, or we loose the
  83.    mirror.
  84.  
  85.  
  86. Version history:
  87.  
  88. 0.1, 2001-04-23:    Initial release.
  89. 0.2, 2001-04-28:    Redirected logging to the listview in GUI mode.
  90.             Minor GUI updates.
  91.  
  92.  
  93. ============================= Archive contents =============================
  94.  
  95. Original  Packed Ratio    Date     Time    Name
  96. -------- ------- ----- --------- --------  -------------
  97.    55690   55690  0.0% 26-Apr-01 20:10:56 +MuMin.lha
  98.     5488    2436 55.6% 27-Mar-01 22:16:56 +MuMin.readme
  99.   124664   53777 56.8% 28-Apr-01 20:31:10 +NallePUH
  100.     2783    1422 48.9% 28-Apr-01 20:17:42 +NallePUH.readme
  101.     6290    1813 71.1% 14-Apr-01 16:55:32 +CompilerSpecific.h
  102.    19064    7097 62.7% 22-Apr-01 16:15:54 +COPYING
  103.      636     362 43.0% 28-Apr-01 20:19:48 +Makefile
  104.    25615    5587 78.1% 28-Apr-01 20:19:48 +Nalle.c
  105.      503     275 45.3% 28-Apr-01 20:19:48 +NallePUH.cd
  106.      368     197 46.4% 23-Apr-01 00:42:28 +NallePUH.h
  107.    24780    7989 67.7% 28-Apr-01 20:19:48 +NallePUH.o
  108.     3290     937 71.5% 28-Apr-01 20:19:48 +NallePUH.res
  109.     4070    1130 72.2% 28-Apr-01 20:19:48 +NallePUHstr.s
  110.     6989    6989  0.0% 23-Apr-01 00:42:30 +pooh11.gif
  111.    78004   32734 58.0% 23-Apr-01 00:42:30 +pooh11.o
  112.    49902    9801 80.3% 28-Apr-01 19:48:32 +PUH.c
  113.     3660    1413 61.3% 28-Apr-01 19:48:32 +PUH.h
  114.     2783    1422 48.9% 28-Apr-01 20:19:48 +README
  115. -------- ------- ----- --------- --------
  116.   414579  191071 53.9% 30-Apr-101 23:48:02   18 files
  117.